<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<c:set var="basePath" value="${pageContext.request.contextPath}" scope="page"></c:set>

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>初级审核</title>
<%-- 
 <link rel="stylesheet" type="text/css" href="${basePath}/static/plugins/web.css" />
<script type="text/javascript" src="${basePath}/static/plugins/switchImag/js/mediabox.js">
<script type="text/javascript" src="${basePath}/static/plugins/switchImag/js/mootools-core.js">
  --%>
 <script type="text/javascript" >
 var url;

	//重置数据
	function resetValue(){
		 
	};
	
	 //客户图片审核弹出窗
	function basiCheck(){
	
		// 获取选中的多行数据
		var selectedRows=$("#dg").datagrid('getSelections');
		//选中单行数据
		var selectedRow =$("#dg").datagrid('getSelected');
		//alert(selectedRow.name);
		//获取选中一行的数据
		if(selectedRow ==null||selectedRow==""){
			$.messager.alert("系统提示","请选择一条要审核的数据！");
			return;
		}
		$("#dlg2").dialog("open").dialog("setTitle","初级信息审核");
		 
     	var base = "${basePath}/"
       var ima0201 = selectedRow.ima0201;
       var img0104 = selectedRow.img0104;
       var img01P5 = selectedRow.img01P5;
     	
      	 if(ima0201==null||ima0201=="")  {
      		 $("#ima02011").remove();
     		 }else  {
     			ima0201 = ima0201.substring(ima0201.indexOf("static"),ima0201.length);
     			ima0201  = base + ima0201;
   			 $("#ima02012").attr("href",ima0201);
        		 $("#ima02013").attr("src",ima0201);
  		 }  
      	 if(img0104==null||img0104=="")  {
      		 $("#img01041").remove();
     		 }else  {
     			img0104 = img0104.substring(img0104.indexOf("static"),img0104.length);
     			img0104  = base + img0104;
   			 $("#img01042").attr("href",img0104);
        		 $("#img01043").attr("src",img0104);
  		 }  
      	 if(img01P5==null||img01P5=="")  {
      		 $("#img01P51").remove();
     		 }else  {
     			img01P5 = img01P5.substring(img01P5.indexOf("static"),img01P5.length);
     			img01P5  = base + img01P5;
   			 $("#img01P52").attr("href",img01P5);
        		 $("#img01P53").attr("src",img01P5);
  		 }  
	  
	};
		
	//关闭窗口
	 function closeBasicDialog(){
			$("#dlg2").dialog("close");
		 
		};
 
		//提交保存用户
		function customerBasicPass(){
			
			$("#fm2").form("submit",{
				url:url,
				
			  	onSubmit:function(){
					return $(this).form("validate");
				},  
				success:function(result){
					if(result){
						 // $.messager.alert("系统提示","保存成功");
						resetValue();
						$("#dlg2").dialog("close");
						$("#dg").datagrid("reload");
					}else{
						$.messager.alert("系统提示","保存失败");
						return;
					}
				}
			});
		};
		
		
 </script>
 
</head>
<!-- 动态加载后台数据 -->
<body style="margin:1px;">
<table id="dg"></table>  
 
 	<!-- 客户照片审核弹窗界面-->
 <div id="dlg2" class="easyui-dialog" resizable="true"  style="width: 800px;height:350px;padding: 10px 20px" 
	  closed="true" buttons="#dlg-button">
	 	<form id="fm2" method="post" >
		<div style="background:#FFF; >
			<!--效果开始-->
			<div class="mod_gallerylist">
			
			  <div  id="ima02011" class="layout_default">
			    <p class="info"><span class="date"></span> <span class="author"></span></p>
			    <div class="image_container">
			    <a id="ima02012" href="" rel="lightbox[ostec]" title="">
			     <img id="ima02013" src="" width="200" height="120" alt="申请表照片" > </a>
			    </div>
			     <span>申请表照片</span>
			  </div>
			  <div  id="img01041" class="layout_default">
			    <p class="info"><span class="date"></span> <span class="author"></span></p>
			    <div class="image_container">
			    <a id="img01042" href="" rel="lightbox[ostec]" title="">
			     <img id="img01043" src="" width="200" height="120" alt="行驶证1" > </a>
			    </div>
			     <span>行驶证1</span>
			  </div>
			  <div  id="img01P51" class="layout_default">
			    <p class="info"><span class="date"></span> <span class="author"></span></p>
			    <div class="image_container">
			    <a id="img01P52" href="" rel="lightbox[ostec]" title="">
			     <img id="img01P53" src="" width="200" height="120" alt="行驶证2" > </a>
			    </div>
			     <span>行驶证2</span>
			  </div>
			 
			 <!--    <div class="layout_default">
			    <p class="info"><span class="date"></span> <span class="author"></span></p>
				    驳回或拒绝理由： <input class="easyui-textbox"  name="failureReason" data-options="multiline:true" style="width:300px;height:100px"/>
			  </div> -->
			  
				</div>
			</div>
			 
		</form>
</div>  

	<!-- 客户基础资料审核  -->
	  <div id="dlg-button">
 
	<!--   <a href="javascript:customerBasicPass()"  class="easyui-linkbutton" iconCls="icon-ok">通过</a>
		<a href="javascript:customerBasicPass()"  id="bohui" class="easyui-linkbutton" iconCls="icon-undo">驳回</a> 
		-->
		<a href="javascript:closeBasicDialog()" class="easyui-linkbutton" iconCls="icon-cancel">关闭</a> 
	</div>  

</body>
</html>